import { request } from '@ruifox-cms/utils'
//创建反馈
export function Createfeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/create',
    method: 'post',
    data
  })
} 
//用户回复
export function userReplyFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/userReply',
    method: 'post',
    // headers: {
    //   'Content-Type': 'application/x-www-form-urlencoded', // 设置请求头
    // },
    data
  })
}
//用户分页查询
export function userPagingFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/userPaging',
    method: 'post',
    data
  })
}
//管理员回复
export function adminReplyFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/adminReply',
    method: 'post',
    data
  })
}
//管理员分页
export function adminPagingFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/adminPaging',
    method: 'post',
    data
  })
}
//获取反馈
export function getThreadDetailFeedback(params) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/getThreadDetail',
    method: 'get',
    params
  })
}
//转交
export function passOnFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/passOn',
    method: 'post',
    headers: {
      'Content-Type': 'application/x-www-form-urlencoded', // 设置请求头
    },
    data
  })
}
//标为未读
export function markAsUnreadFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/markAsUnread',
    method: 'post',
    data
  })
}
//标为已读
export function markAsReadFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/markAsRead',
    method: 'post',
    data
  })
}
//关闭反馈
export function closeFeedback(data) {
  return request({
    baseURL: "/10101_api",
    url: '/oltes/api/v1/system/feedback/close',
    method: 'post',
    headers: {
      'Content-Type': 'application/x-www-form-urlencoded', // 设置请求头
    },
    data
  })
}